import Vue from 'vue'
import Router from 'vue-router'
import QuXianSD from "@/components/QuXianSD";
import QuXianGZ from "@/components/QuXianGZ";
import QuXianWD from "../components/QuXianWD";
import ExcelSD from "@/components/ExcelSD";
import ExcelGQ from "@/components/ExcelGQ";
import ExcelWD from "../components/ExcelWD";
import ZhuZhuangGQ from "@/components/ZhuZhuangGQ";
import ZhuZhuangSD from "@/components/ZhuZhuangSD";
import ZhuZhuangWD from "../components/ZhuZhuangWD";
import MainContent from "../components/MainContent";
import Index from "../components/Index";

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'Index',
      //redirect重新使用
      redirect: '/mainContent',
      component: Index,
      children:[
        {
          path: '/mainContent',
          name: 'MainContent',
          component: MainContent,
          children:[
            {
              path: '/QuXianSD',
              name: '湿度曲线',
              component: QuXianSD,
            },
            {
              path: '/QuXianGZ',
              name: '光强曲线',
              component: QuXianGZ,
            },
            {
              path: '/QuXianWD',
              name: '温度曲线',
              component: QuXianWD,
            },
            {
              path: '/ExcelGQ',
              name: '光强列表',
              component: ExcelGQ,
            },
            {
              path: '/',
              name: 'index',
              component: ZhuZhuangGQ,
            },
            {
              path: '/ZhuZhuangGQ',
              name: '光强柱状',
              component: ZhuZhuangGQ,
            },
            {
              path: '/ZhuZhuangSD',
              name: '湿度柱状',
              component: ZhuZhuangSD,
            },
            {
              path: '/ZhuZhuangWD',
              name: '温度柱状',
              component: ZhuZhuangWD,
            },
            {
              path: '/ExcelSD',
              name: '湿度列表',
              component: ExcelSD,
            },
            {
              path: '/ExcelGQ',
              name: '光强列表',
              component: ExcelGQ,
            },
            {
              path: '/ExcelWD',
              name: '温度列表',
              component: ExcelWD,
            }
          ]
        }
      ]
    }
  ]
})
